<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

class CreateAkbusFixedCostTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('akbus_fixed_cost', function (Blueprint $table) {
            $table->id();
            $table->string('type')->nullable()->comment('类型');
            $table->decimal('amount', 10, 2)->nullable()->comment('金额');
            $table->date('start_at')->nullable()->comment('开始时间');
            $table->date('end_at')->nullable()->comment('结束时间');
            $table->tinyInteger('object_type')->nullable()->comment('推送对象');
            $table->tinyInteger('bus_type')->nullable()->comment('车辆类型');
            $table->tinyInteger('bus_brand')->nullable()->comment('车辆品牌');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('akbus_fixed_cost');
    }
}
